import React from 'react';
import personalDataPic from '@/assets/entry/personalDataPic_0.png';
import styles from './index.less';

// 入职对外页面头部banner
const TopBanner = ({ employeeName, space = 98, partLeft = {}, partRight = {}, wrapStyles }) => {
    const { styles: leftStyles, render: leftRender, className: leftClassName } = partLeft;
    const { styles: rightStyles, render: rightRender, className: rightClassName } = partRight;
    return (
        <div className={styles.topBannerWrap} styles={wrapStyles}>
            <div className={leftClassName || styles.leftText} styles={leftStyles}>
                {leftRender || <>你好 {employeeName && <>，{employeeName}</>}</>}
            </div>
            <div className={styles.middleSapce} style={{ width: space }}></div>
            <div className={rightClassName} styles={rightStyles}>
                {rightRender || <img src={personalDataPic} alt="" />}
            </div>
        </div>
    );
};

export default TopBanner;
